package com.diandian.backend.dingding.data.clients;

import com.diandian.backend.dingding.data.clients.dto.OapiV2DepartmentListsubResponse;
import com.diandian.base.boot.starter.response.BaseResult;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;

@FeignClient("diandian-dingding-exchange")
//@FeignClient(value = "business-diandian-sms", url = "http://localhost:8083", path = "")
public interface DianDianDingDingExhcangeClient {

    /**
     * 获取部门列表
     * @param dingDeptId
     * @return
     */
    @GetMapping("/dept/getDeptList")
    OapiV2DepartmentListsubResponse getDeptList(@RequestHeader(value = "appKey") String appKey,
                                                @RequestHeader(value = "appSecret") String appSecret,
                                                @RequestParam(value = "dingDeptId") Long dingDeptId,
                                                @RequestParam(value = "language") String language);
    /**
     * 获取部门用户详情(全部）
     */
    @GetMapping("/user/getAllDeptUserDetail")
    BaseResult getAllDeptUserDetail(@RequestHeader(value = "appKey") String appKey,
                                    @RequestHeader(value = "appSecret") String appSecret,
                                    @RequestParam(value = "dingDeptId") Long dingDeptId,
                                    @RequestParam(value = "orderField", required = false) String orderField,
                                    @RequestParam(value = "containAccessLimit", required = false) Boolean containAccessLimit,
                                    @RequestParam(value = "language", required = false) String language);
}
